home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Ham Radio 2000 #2
/
Ham Radio 2000 - Volume 2.iso
/
HAMV2
/
ANTENNA
/
YAGIU112
/
Z_INPUT.C
< prev
next >
Wrap
C/C++ Source or Header
|
1995-08-07
|
537b
|
25 lines
#include <stdio.h>
#include <math.h>
#include <errno.h>
#include "yagi.h"
extern int errno;
/* compute the input impedance (driving impedance) */
void z_input(struct FCOMPLEX v, struct FCOMPLEX i, struct FCOMPLEX *impedance)
{
*impedance=Cdiv(v,i);
/* printf("Voltage=%lf + i %lf\n", v.r, v.i);
printf("Current = %lf + i %lf \n", i.r, i.i);
printf("Z = V/I = %lf + %lf \n", impedance->r, impedance->i); */
#ifdef DEBUG
if(errno)
{
fprintf(stderr,"Errno =%d in z_input() in z_input.c\n", errno);
exit(1);
}
#endif
}